edge = int(input('input triangle lines:'))

basic = [1]
nums = []
last = []
for i in range(1, edge + 1):
    nums = (basic * i)
    for j in range(1, i - 1):
        if i < 3:
            break
        nums[j] = last[j] + last[j - 1]
    last = nums
    print(nums)
